package com.codeduck.mock.utils;

import java.io.File;

/**
 * @author: <a href="mailto:codeduck@163.com">codeduck</a>
 * @date: 2022/12/05
 */
public class AppUtil {

    public static String staticMethod(String var) {
        return "AppUtil.staticMethod: " + var;
    }

    public boolean fileExists(String path) {
        File file = new File(path);
        try {
            if (file.exists()) {
                System.out.println("存在");

                return true;
            } else {
                System.out.println("不存在");
                return false;
            }
        } catch (Exception e) {
            System.out.println("输出异常");
            throw new RuntimeException(e);
        }
    }
}
